Fix bug #9530 with incorrect display of zero-width stretch.
authorEli Zaretskii <eliz@gnu.org>
Sat, 17 Sep 2011 18:21:24 +0000 (21:21 +0300)
committerEli Zaretskii <eliz@gnu.org>
Sat, 17 Sep 2011 18:21:24 +0000 (21:21 +0300)
 src/xdisp.c (produce_stretch_glyph): Another fix for changes made on
 2011-08-30 (revision 105619).

src/ChangeLog
src/xdisp.c

index dc91f1d4a03c892070a4e4f95d175d381a5a8d77..9f43072190b0cac5fd59502b3ea3665d3a5899b7 100644 (file)
@@ -1,3 +1,8 @@
+2011-09-17  Eli Zaretskii  <eliz@gnu.org>
+
+       * xdisp.c (produce_stretch_glyph): Another fix for changes made on
+       2011-08-30 (revision 105619).  (Bug#9530)
+
 2011-09-17  Eli Zaretskii  <eliz@gnu.org>
 
        * xdisp.c (reseat_at_next_visible_line_start): Keep information
index 3cb9f301bb2466a4012fcc009ac48da8a422989b..f889815fa1e929cd43b4ad401c21f2820eba6b04 100644 (file)
@@ -23298,14 +23298,7 @@ produce_stretch_glyph (struct it *it)
        object = it->w->buffer;
 #ifdef HAVE_WINDOW_SYSTEM
       if (FRAME_WINDOW_P (it->f))
-       {
-         append_stretch_glyph (it, object, width, height, ascent);
-         it->pixel_width = width;
-         it->ascent = it->phys_ascent = ascent;
-         it->descent = it->phys_descent = height - it->ascent;
-         it->nglyphs = width > 0 && height > 0 ? 1 : 0;
-         take_vertical_position_into_account (it);
-       }
+       append_stretch_glyph (it, object, width, height, ascent);
       else
 #endif
        {
@@ -23317,6 +23310,19 @@ produce_stretch_glyph (struct it *it)
          it->object = o_object;
        }
     }
+
+  it->pixel_width = width;
+#ifdef HAVE_WINDOW_SYSTEM
+  if (FRAME_WINDOW_P (it->f))
+    {
+      it->ascent = it->phys_ascent = ascent;
+      it->descent = it->phys_descent = height - it->ascent;
+      it->nglyphs = width > 0 && height > 0 ? 1 : 0;
+      take_vertical_position_into_account (it);
+    }
+  else
+#endif
+    it->nglyphs = width;
 }
 
 #ifdef HAVE_WINDOW_SYSTEM